from abc import ABC, abstractmethod

class IRepoService(ABC):
    @abstractmethod
    async def mount_repo(self, name: str) -> dict:
        pass

    @abstractmethod
    async def unmount_repo(self, repo_key: str) -> dict:
        pass
    
    @abstractmethod
    async def update_repo(self, repo_key: str, update_key: str, update_value: str) -> dict:
        pass

    @abstractmethod
    async def list_repos(self) -> dict:
        pass
    
class IEntryService(ABC):
    @abstractmethod
    async def create_entry(self, repo_key: str, entry_path: str, is_dir: bool) -> dict:
        pass
    
    @abstractmethod
    async def delete_entry(self, repo_key: str, entry_key: str) -> dict:
        pass
    
    @abstractmethod
    async def update_entry(self, repo_key: str, entry_key: str, update_key: str, update_value: str) -> dict:
        pass
    
    @abstractmethod
    async def get_entry_children(self, entry_key: str) -> list[dict]:
        pass
    
class IFileService(ABC):
    @abstractmethod
    async def create_file(self, repo_key: str, file_name: str, object_key: str) -> dict:
        pass

    @abstractmethod
    async def update_file(self, repo_key: str, file_key: str, update_key: str, update_value: str) -> dict:
        pass

    @abstractmethod
    async def metadata(self, repo_key: str, file_key: str) -> dict:
        pass

class IVersionService(ABC):
    @abstractmethod
    async def create_version(self, repo_key: str, file_key: str, object_key: str) -> dict:
        pass
    
    @abstractmethod
    async def update_version(self, repo_key: str, object_key: str, update_key: str, update_value: str) -> dict:
        pass

    @abstractmethod
    async def version_list(self, repo_key: str, file_key: str) -> list[dict]:
        pass

